# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.MigrationCenter.V1.Model.GuestRuntimeDetails do
  @moduledoc """
  Guest OS runtime information.

  ## Attributes

  *   `domain` (*type:* `String.t`, *default:* `nil`) - Domain, e.g. c.stratozone-development.internal.
  *   `installedApps` (*type:* `GoogleApi.MigrationCenter.V1.Model.GuestInstalledApplicationList.t`, *default:* `nil`) - Installed applications information.
  *   `lastBootTime` (*type:* `DateTime.t`, *default:* `nil`) - Last time the OS was booted.
  *   `machineName` (*type:* `String.t`, *default:* `nil`) - Machine name.
  *   `network` (*type:* `GoogleApi.MigrationCenter.V1.Model.RuntimeNetworkInfo.t`, *default:* `nil`) - Runtime network information (connections, ports).
  *   `openFileList` (*type:* `GoogleApi.MigrationCenter.V1.Model.OpenFileList.t`, *default:* `nil`) - Open files information.
  *   `processes` (*type:* `GoogleApi.MigrationCenter.V1.Model.RunningProcessList.t`, *default:* `nil`) - Running processes.
  *   `services` (*type:* `GoogleApi.MigrationCenter.V1.Model.RunningServiceList.t`, *default:* `nil`) - Running background services.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :domain => String.t() | nil,
          :installedApps =>
            GoogleApi.MigrationCenter.V1.Model.GuestInstalledApplicationList.t() | nil,
          :lastBootTime => DateTime.t() | nil,
          :machineName => String.t() | nil,
          :network => GoogleApi.MigrationCenter.V1.Model.RuntimeNetworkInfo.t() | nil,
          :openFileList => GoogleApi.MigrationCenter.V1.Model.OpenFileList.t() | nil,
          :processes => GoogleApi.MigrationCenter.V1.Model.RunningProcessList.t() | nil,
          :services => GoogleApi.MigrationCenter.V1.Model.RunningServiceList.t() | nil
        }

  field(:domain)
  field(:installedApps, as: GoogleApi.MigrationCenter.V1.Model.GuestInstalledApplicationList)
  field(:lastBootTime, as: DateTime)
  field(:machineName)
  field(:network, as: GoogleApi.MigrationCenter.V1.Model.RuntimeNetworkInfo)
  field(:openFileList, as: GoogleApi.MigrationCenter.V1.Model.OpenFileList)
  field(:processes, as: GoogleApi.MigrationCenter.V1.Model.RunningProcessList)
  field(:services, as: GoogleApi.MigrationCenter.V1.Model.RunningServiceList)
end

defimpl Poison.Decoder, for: GoogleApi.MigrationCenter.V1.Model.GuestRuntimeDetails do
  def decode(value, options) do
    GoogleApi.MigrationCenter.V1.Model.GuestRuntimeDetails.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.MigrationCenter.V1.Model.GuestRuntimeDetails do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
